package cn.dlc.com.biz.user.controller;

import cn.dlc.com.biz.user.entity.User;
import cn.dlc.com.biz.user.mapper.UserMapper;
import cn.dlc.com.biz.user.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author: dlc
 * @Date: 2021/11/8 - 16:44
 */

@RestController
@RequestMapping("user")
public class UserController {

    @Autowired
    private UserService userService;

    @Autowired
    private UserMapper userMapper;


    @GetMapping
    public List<User> findAll(){

        userMapper.findAll();

        return userService.findAll();

    }
}
